(#67542, reported by Anders Carlsson)
authorOwen Taylor <otaylor@redhat.com>
Wed, 26 Dec 2001 17:06:13 +0000 (17:06 +0000)
committerOwen Taylor <otaylor@src.gnome.org>
Wed, 26 Dec 2001 17:06:13 +0000 (17:06 +0000)
Wed Dec 26 11:49:01 2001  Owen Taylor  <otaylor@redhat.com>

        (#67542, reported by Anders Carlsson)

        * gtk/gtkstyle.c (gtk_style_real_init_from_rc): Merge
        rc_style->font_desc with defaul style instead of replacing
        it.

        * gtk/gtkrc.c (gtk_rc_style_real_merge): Allow partial
        font descriptions in RC styles by calling
        pango_font_description_merge().

ChangeLog
ChangeLog.pre-2-0
ChangeLog.pre-2-10
ChangeLog.pre-2-2
ChangeLog.pre-2-4
ChangeLog.pre-2-6
ChangeLog.pre-2-8
gtk/gtkrc.c
gtk/gtkstyle.c

index b77bbf5dcb3e6e6f05f03f305754811d4b2dfcf7..a0fb1c8be589dc4c026ea5b45f4976afd973d60c 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,15 @@
+Wed Dec 26 11:49:01 2001  Owen Taylor  <otaylor@redhat.com>
+
+       (#67542, reported by Anders Carlsson)
+       
+       * gtk/gtkstyle.c (gtk_style_real_init_from_rc): Merge
+       rc_style->font_desc with defaul style instead of replacing
+       it.
+
+       * gtk/gtkrc.c (gtk_rc_style_real_merge): Allow partial
+       font descriptions in RC styles by calling
+       pango_font_description_merge(). 
+
 2001-12-24  James Henstridge  <james@daa.com.au>
 
        * gtk/gtkdialog.h (doc comment): s/<!>/<!-- -->/ to make the doc
index b77bbf5dcb3e6e6f05f03f305754811d4b2dfcf7..a0fb1c8be589dc4c026ea5b45f4976afd973d60c 100644 (file)
@@ -1,3 +1,15 @@
+Wed Dec 26 11:49:01 2001  Owen Taylor  <otaylor@redhat.com>
+
+       (#67542, reported by Anders Carlsson)
+       
+       * gtk/gtkstyle.c (gtk_style_real_init_from_rc): Merge
+       rc_style->font_desc with defaul style instead of replacing
+       it.
+
+       * gtk/gtkrc.c (gtk_rc_style_real_merge): Allow partial
+       font descriptions in RC styles by calling
+       pango_font_description_merge(). 
+
 2001-12-24  James Henstridge  <james@daa.com.au>
 
        * gtk/gtkdialog.h (doc comment): s/<!>/<!-- -->/ to make the doc
index b77bbf5dcb3e6e6f05f03f305754811d4b2dfcf7..a0fb1c8be589dc4c026ea5b45f4976afd973d60c 100644 (file)
@@ -1,3 +1,15 @@
+Wed Dec 26 11:49:01 2001  Owen Taylor  <otaylor@redhat.com>
+
+       (#67542, reported by Anders Carlsson)
+       
+       * gtk/gtkstyle.c (gtk_style_real_init_from_rc): Merge
+       rc_style->font_desc with defaul style instead of replacing
+       it.
+
+       * gtk/gtkrc.c (gtk_rc_style_real_merge): Allow partial
+       font descriptions in RC styles by calling
+       pango_font_description_merge(). 
+
 2001-12-24  James Henstridge  <james@daa.com.au>
 
        * gtk/gtkdialog.h (doc comment): s/<!>/<!-- -->/ to make the doc
index b77bbf5dcb3e6e6f05f03f305754811d4b2dfcf7..a0fb1c8be589dc4c026ea5b45f4976afd973d60c 100644 (file)
@@ -1,3 +1,15 @@
+Wed Dec 26 11:49:01 2001  Owen Taylor  <otaylor@redhat.com>
+
+       (#67542, reported by Anders Carlsson)
+       
+       * gtk/gtkstyle.c (gtk_style_real_init_from_rc): Merge
+       rc_style->font_desc with defaul style instead of replacing
+       it.
+
+       * gtk/gtkrc.c (gtk_rc_style_real_merge): Allow partial
+       font descriptions in RC styles by calling
+       pango_font_description_merge(). 
+
 2001-12-24  James Henstridge  <james@daa.com.au>
 
        * gtk/gtkdialog.h (doc comment): s/<!>/<!-- -->/ to make the doc
index b77bbf5dcb3e6e6f05f03f305754811d4b2dfcf7..a0fb1c8be589dc4c026ea5b45f4976afd973d60c 100644 (file)
@@ -1,3 +1,15 @@
+Wed Dec 26 11:49:01 2001  Owen Taylor  <otaylor@redhat.com>
+
+       (#67542, reported by Anders Carlsson)
+       
+       * gtk/gtkstyle.c (gtk_style_real_init_from_rc): Merge
+       rc_style->font_desc with defaul style instead of replacing
+       it.
+
+       * gtk/gtkrc.c (gtk_rc_style_real_merge): Allow partial
+       font descriptions in RC styles by calling
+       pango_font_description_merge(). 
+
 2001-12-24  James Henstridge  <james@daa.com.au>
 
        * gtk/gtkdialog.h (doc comment): s/<!>/<!-- -->/ to make the doc
index b77bbf5dcb3e6e6f05f03f305754811d4b2dfcf7..a0fb1c8be589dc4c026ea5b45f4976afd973d60c 100644 (file)
@@ -1,3 +1,15 @@
+Wed Dec 26 11:49:01 2001  Owen Taylor  <otaylor@redhat.com>
+
+       (#67542, reported by Anders Carlsson)
+       
+       * gtk/gtkstyle.c (gtk_style_real_init_from_rc): Merge
+       rc_style->font_desc with defaul style instead of replacing
+       it.
+
+       * gtk/gtkrc.c (gtk_rc_style_real_merge): Allow partial
+       font descriptions in RC styles by calling
+       pango_font_description_merge(). 
+
 2001-12-24  James Henstridge  <james@daa.com.au>
 
        * gtk/gtkdialog.h (doc comment): s/<!>/<!-- -->/ to make the doc
index b77bbf5dcb3e6e6f05f03f305754811d4b2dfcf7..a0fb1c8be589dc4c026ea5b45f4976afd973d60c 100644 (file)
@@ -1,3 +1,15 @@
+Wed Dec 26 11:49:01 2001  Owen Taylor  <otaylor@redhat.com>
+
+       (#67542, reported by Anders Carlsson)
+       
+       * gtk/gtkstyle.c (gtk_style_real_init_from_rc): Merge
+       rc_style->font_desc with defaul style instead of replacing
+       it.
+
+       * gtk/gtkrc.c (gtk_rc_style_real_merge): Allow partial
+       font descriptions in RC styles by calling
+       pango_font_description_merge(). 
+
 2001-12-24  James Henstridge  <james@daa.com.au>
 
        * gtk/gtkdialog.h (doc comment): s/<!>/<!-- -->/ to make the doc
index 355a134aa946c8485e709ca5e9054c80ee114030..ab453891d964790d6487ab7d9b8c03e83b626d0c 100644 (file)
@@ -1176,8 +1176,13 @@ gtk_rc_style_real_merge (GtkRcStyle *dest,
   if (dest->ythickness < 0 && src->ythickness >= 0)
     dest->ythickness = src->ythickness;
 
-  if (!dest->font_desc && src->font_desc)
-    dest->font_desc = pango_font_description_copy (src->font_desc);
+  if (src->font_desc)
+    {
+      if (!dest->font_desc)
+       dest->font_desc = pango_font_description_copy (src->font_desc);
+      else
+       pango_font_description_merge (dest->font_desc, src->font_desc, FALSE);
+    }
 
   if (src->rc_properties)
     {
index 096e98ad8b2d5ead308d7e7d9ec9a94442f00f13..ed8a4ba5b14b83f9b81c856eaab0e635384f9028 100644 (file)
@@ -1239,10 +1239,7 @@ gtk_style_real_init_from_rc (GtkStyle   *style,
   clear_property_cache (style);
 
   if (rc_style->font_desc)
-    {
-      pango_font_description_free (style->font_desc);
-      style->font_desc = pango_font_description_copy (rc_style->font_desc);
-    }
+    pango_font_description_merge (style->font_desc, rc_style->font_desc, TRUE);
     
   for (i = 0; i < 5; i++)
     {